import request from '@/utils/request'
// 运营人员
export const GetMan = innerCode => request.get('/api/user-service/user/operatorList/' + innerCode)
// 设备商品
export const GetGoods = innerCode => request.get('/api/vm-service/channel/channelList/' + innerCode)
// 创建工单
export const CreateWorkOrder = data => request.post('/api/task-service/task/create', data)
// 搜索工单
export const SearchWorkOrder = params => request.get('/api/task-service/task/search', { params })
// 获取工单详情
export const GetWorkOrder = taskId => request.get('/api/task-service/task/taskInfo/' + taskId)

export const WorkOrderState = () => request.get('/api/task-service/task/allTaskStatus')

export const GetWorkOrderList = () => request.get('/api/task-service/taskType/list')
// 补货详情
export const GetReplenishment = taskId => request.get('/api/task-service/taskDetails/' + taskId)
// 警戒线
export const GetAlert = alertValue => request.get('/api/task-service/task/supplyAlertValue', alertValue)
// 设置自动补货工单阈值
export const SetAlertValue = alertValue => request.post('/api/task-service/task/autoSupplyConfig', { alertValue })
// 取消工单
export const CancelOder = (taskId, desc) => request.post('/api/task-service/task/cancel/' + taskId, { taskId, desc })
// 运维人员
export const GetYwMan = innerCode => request.get('/api/user-service/user/repairerList/' + innerCode)
